import request from '@/utils/system/request'

// 获取菜单树形结构
export function treeData(params) {
    return request({
        url: '/menu/tree',
        method: 'get',
        params
    })
}


//删除菜单
export function deleteMenu(params) {
    return request({
        url: '/menu/delete',
        method: 'delete',
        params
    });
}

//新增菜单
export function addMenu(data) {
    return request({
        url: '/menu/add',
        method: 'post',
        data
    });
}

//编辑菜单
export function editMenu(data) {
    return request({
        url: '/menu/edit',
        method: 'put',
        data
    });
}